package com.dataeco.api.repository;

import com.dataeco.api.entity.BankAccount;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import java.util.List;

public interface BankAccountRepository extends JpaRepository<BankAccount,String>{
    @Query("select ba from BankAccount as ba where ba.user.id=:userId")
    public List<BankAccount> findByUserId(@Param("userId") String userId);
}
